import multiprocessing
import time


def task(delay, count):
	for num in range(count):
		print(
			f"【count = {num}】  "
			f"进程ID={multiprocessing.current_process().pid} "
			f"进程名称={multiprocessing.current_process().name}"
		)
		time.sleep(delay)



def main():
	for item in range(3):
		process = multiprocessing.Process(
			target=task,  # 每个进程的任务
			args=(1, 10,),  # 业务函数的参数
			name=f"业务处理进程--{item}"  # 进程名称
		)
		process.start()  # 启动进程


if __name__ == '__main__':
	main()
